<%@page import="modulo1.cdp.EnumArea"%>
<%@page import="modulo1.cdp.EnumTipo"%>
<div class="table" style="border-top:2px solid #f70;">
    <br />
    <form method="post" id="evento">
        <input type="hidden" name="evento" value="alterar" />
        <a id="salvar" class="button" style="cursor: pointer;">Salvar</a>
        <a class="button" style="cursor: pointer;" onclick="history.back(-1)">Voltar</a><br />
        <table class="listing form" cellpadding="0" cellspacing="0">
            <tr>
                <th class="full" colspan="2">Aluno</th>
            </tr>
            <tr>
                <td class="first" width="172"><strong>Nome</strong></td>
                <td class="last"><input type="text" id="nome" name="nome" class="text" /></td>
            </tr
            <tr>
                <td class="first" width="172"><strong>Email</strong></td>
                <td class="last"><input type="text" id="email" name="email" class="text" /></td>
            </tr>
            <tr>
                <td class="first" width="172"><strong>Endereco</strong></td>
                <td class="last"><input type="text" id="endereco" name="endereco" class="text" /></td>
            </tr>
            <tr>
                <td class="first" width="172"><strong>Telefone</strong></td>
                <td class="last"><input type="text" id="telefone" name="telefone" class="text" /></td>
            </tr>
            <tr>
                <td class="first" width="172"><strong>Sexo</strong></td>
                <td class="last">
                    <input type="radio" id="sexo1" name="sexo" value="M"> Masculino<br>
                    <input type="radio" id="sexo2" name="sexo" value="F"> Feminino</td>
            </tr> 
            <tr>
                <td class="first" width="172"><strong>Naturalidade</strong></td>
                <td class="last"><input type="text" id="naturalidade" name="naturalidade" class="text" /></td>
            </tr>
            <tr>
            <td class="first" width="172"><strong>Data de Nascimento</strong></td>
            <td class="last"><input type="text" id="dataNascimento" name="dataNascimento" class="text" /></td>
            </tr>
            <tr>
                <td class="first" width="172"><strong>RG</strong></td>
                <td class="last"><input type="text" id="rg" name="rg" class="text" /></td>
            </tr>
            <tr>
                <td class="first" width="172"><strong>Login</strong></td>
                <td class="last"><input type="text" id="login" name="login" class="text" /></td>
            </tr>
            <tr>
                <td class="first" width="172"><strong>Senha</strong></td>
                <td class="last"><input type="text" id="senha" name="senha" class="text" /></td>
            </tr>
        </table>
        <p>&nbsp;</p>
    </form>
</div>
<script>
    $("#salvar").click(function(){
        if($("#nome").val().length == 0) {
            alert("Informar nome");
            $("#nome").focus();
            return false;
        }
        if($("#email").val().length == 0) {
            alert("Informar email");
            $("#email").focus();
            return false;
        }
        if($("#endereco").val().length == 0) {
            alert("Informar endereco");
            $("#endereco").focus();
            return false;
        }
        if($("#telefone").val().length == 0) {
            alert("Informar telefone");
            $("#telefone").focus();
            return false;
        }
        if($("#naturalidade").val().length == 0) {
            alert("Informar naturalidade");
            $("#naturalidade").focus();
            return false;
        }
        if($("#dataNascimento").val().length == 0) {
            alert("Informar valor data nascimento");
            $("#dataNascimento").focus();
            return false;
        }
        if($("#rg").val().length == 0) {
            alert("Informar rg");
            $("#rg").focus();
            return false;
        }
        if($("#login").val().length == 0) {
            alert("Informar login");
            $("#login").focus();
            return false;
        }
        if($("#senha").val().length == 0) {
            alert("Informar senha");
            $("#senha").focus();
            return false;
        }
        $("#evento").submit();
    });
</script>